package org.wu.reggie.mapper;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.wu.reggie.entity.DishFlavor;

import java.util.List;

public interface DishFlavorMapper {

    void saveBatch(@Param("dishFlavorList") List<DishFlavor> dishFlavorList);

    @Select("select * from dish_flavor where dish_id=#{dishId}")
    List<DishFlavor> findByDishId(Long dishId);

    @Delete("delete from dish_flavor where dish_id=#{dishId}")
    void deleteByDishId(Long dishId);
}
